home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1996 July: Mac OS SDK / Dev.CD Jul 96 SDK / Dev.CD Jul 96 SDK2.toast / Development Kits (Disc 2) / Open Transport / Sample Code / DLPI / ATM PCI DLPI / Sources / ATMDebug.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-05-15  |  1.2 KB  |  56 lines  |  [TEXT/MPS ]

  1. /***********************************************************
  2.     File:        ATMDebug.h
  3.  
  4.     Contains:    Debugging utilities declarations for the ATM
  5.                             Streams drivers/modules
  6.     
  7.     Written by:    
  8.  
  9.     Copyright:    © 1994 by Apple Computer, Inc., all rights reserved.
  10.  
  11.     Change History (most recent first):
  12.     
  13.     To Do:
  14.  ***********************************************************/
  15.  
  16. /*
  17.  * If ATM_DEBUG is defined, then these debugging utilities
  18.  * will be activated.
  19.  */
  20.  
  21. #ifndef __ATMDEBUG__
  22. #define __ATMDEBUG__
  23.  
  24. #include <OpenTptModule.h>
  25.  
  26. #ifdef ATM_DEBUG
  27.  
  28. #define DEBUG_SPRINTF(arg) sprintf arg
  29. #define DEBUG_BREAK(arg) debugstr(arg)
  30. #define DUMP_DLPI_MSG(arg) dump_dlpi_msg(arg)
  31. #define DUMP_TPI_MSG(arg) dump_tpi_msg(arg)
  32.  
  33. #else /* no ATM_DEBUG */
  34.  
  35. #define DEBUG_SPRINTF(arg)
  36. #define DEBUG_BREAK(arg)
  37. #define DUMP_DLPI_MSG(arg)
  38. #define DUMP_TPI_MSG(arg)
  39.  
  40. #endif
  41.  
  42. #define ERROR_SPRINTF(arg) sprintf arg
  43. #define ERROR_BREAK(arg) debugstr(arg)
  44.  
  45. #define FATAL_SPRINTF(arg) sprintf arg
  46. #define FATAL_BREAK(arg) debugstr(arg)
  47.  
  48. extern char* stream_msg_type(mblk_t *mp);
  49. extern char* tpi_msg_type(mblk_t *mp);
  50. extern char *dlpi_msg_type(mblk_t *mp);
  51.  
  52. extern void dump_dlpi_msg(mblk_t* mp);
  53. extern void dump_tpi_msg(mblk_t* mp);
  54.  
  55. #endif        /* __ATMDEBUG__ */
  56.